<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
<script>
    var i=prompt("请输入体重(kg)");
    var x=prompt("请输入身高(M)");
    var y=x*x;
    var c=i/y
    if(c<=18.5){
        alert("体重过低")
    }
    if(18.5< c && c<23.9){
        alert("体重正常")
    }
    if(24< c && c <27.9){
        alert("体重过重")
    }
    if(c >=28.0){
        alert("体重肥胖")
    }
</script>
</html>